package com.handsome.原型模式.原型模式;

/**
 * @author niechun
 * @date 2023/1/17 19:51
 */
public class Client {
    public static void main(String[] args) throws CloneNotSupportedException {

        Sheep sheep=new Sheep();
        sheep.setAge(10);
        sheep.setName("多利");
        //克隆羊
        Sheep clone = sheep.clone();
        //原型
        System.out.println(sheep);
        //克隆
        System.out.println(clone);

    }
}
